<template>
	<view class="menu-container">
		<scroll-view class="menu" scroll-x="true">
			<view class="menu-item" @tap="tapItem" data-index="1">
				<text class="iconfont iconzuoyetongzhi"></text>
				<view class="menu-lable">作业历史</view>
			</view>
			<view class="menu-item" @tap="tapItem" data-index="2">
				<text class="iconfont iconhuiyitongzhi"></text>
				<view class="menu-lable meeting">会议历史</view>
			</view>
			<view class="menu-item" @tap="tapItem" data-index="3">
				<view style="margin-bottom: 14rpx;"><text class="iconfont iconmenjinshuliang"></text></view>
				<view class="menu-lable">门禁历史</view>
			</view>
			<view class="menu-item" @tap="tapItem" data-index="4">
				<view style="margin-bottom: 6rpx;"><text class="iconfont iconchengjitongzhi"></text></view>
				<view class="menu-lable">成绩历史</view>
			</view>
			<view class="menu-item" @tap="tapItem" data-index="5">
				<view style="margin-bottom: 20rpx;"><text class="iconfont iconxiaoche"></text></view>
				<view class="menu-lable">校车历史</view>
			</view>
			<view class="menu-item" @tap="tapItem" data-index="6">
				<view style="margin-bottom: 18rpx;"><text class="iconfont iconkecheng"></text></view>
				<view class="menu-lable">课程历史</view>
			</view>
			<view class="menu-item" @tap="tapItem" data-index="7">
				<view style="margin-bottom: 16rpx;"><text class="iconfont icontemperature"></text></view>
				<view class="menu-lable">体温监测</view>
			</view>
		</scroll-view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
	
			}
		},
		methods: {
			tapItem(e) {
				let index = e.currentTarget.dataset.index
				switch (index) {
					case '1':
						uni.navigateTo({
							url: '/pages/teacher_homework/teacher_homework'
						})
						break
					case '2':
						uni.navigateTo({
							url: '/pages/teacher_meeting/teacher_meeting'
						})
						break
					case '3':
						uni.navigateTo({
							url: '/pages/teacher_access_control/teacher_access_control'
						})
						break
					case '4':
						uni.navigateTo({
							url: '/pages/teacher_grade/teacher_grade'
						})
						break
					case '5':
						uni.navigateTo({
							url: '/pages/teacher_school_bus/teacher_school_bus'
						})
						break
					case '6':
						uni.navigateTo({
							url: '/pages/teacher_course/teacher_course'
						})
						break
					case '7':
						uni.navigateTo({
							url: '/pages/teacher_temperature/teacher_temperature'
						})
						break
					default:
						break
				}
			}
		}
	}
</script>

<style>
	@font-face {
		font-family: 'iconfont';  /* project id 1705280 */
		src: url('https://at.alicdn.com/t/font_1705280_otaltml7zrq.ttf') format('truetype');
	}

	.iconfont {
		font-family: "iconfont" !important;
		font-size: 60rpx;
		font-style: normal;
		-webkit-font-smoothing: antialiased;
		-moz-osx-font-smoothing: grayscale;
	}

	.icontemperature:before {
		content: "\e609";
		font-size: 70rpx;
	}

	.iconkecheng:before {
		content: "\e600";
		font-size: 70rpx;
	}

	.iconmenjinshuliang:before {
		content: "\e639";
		font-size: 86rpx;
	}

	.iconhuiyitongzhi:before {
		content: "\e60e";
		font-size: 110rpx;
	}

	.iconzuoyetongzhi:before {
		content: "\e60d";
		font-size: 110rpx;
	}

	.iconxiaoche:before {
		content: "\e6e5";
		font-size: 70rpx;
	}

	.iconchengjitongzhi:before {
		content: "\e60c";
		font-size: 100rpx;
	}

	.iconicon-test:before {
		content: "\e63f";
	}

	.icontongzhi:before {
		content: "\e60a";
	}

	.menu-container {
		width: 680rpx;
		overflow: hidden;
		margin-top: 20rpx;
	}

	.menu {
		white-space: nowrap;
	}

	.menu-item {
		width: 140rpx;
		height: 180rpx;
		display: inline-block;
		text-align: center;
	}

	.menu-lable {
		font-size: 28rpx;
	}
</style>
